import { Component } from '@angular/core';

@Component({
  selector: 'app-demo3',
  templateUrl: './demo3.component.html'
})
export class Demo3Component {
  selected1 = 'item002';
  selected2 = 'item002';
  btnText = 'Disable';
  disabled = false;

  disable() {
    this.disabled = !this.disabled;
    if(this.disabled){
      this.btnText = 'Enable';
    } else {
      this.btnText = 'Disable';
    }
  }
}